'REQUEST' '"Error when saving temporary image!"' '" OK "'
CALL ErrorOut 10
END
ADDRESS "IMAGEFX.1"
Screen2Front
LoadBuffer '"'TEMP_FILE'"' force
IF (RC ~= 0) THEN DO
ADDRESS 'IMAGEENGINEER'
'REQUEST' '"Error when loading temporary image into ImageFX!"' '" OK "'
CALL ErrorOut 10
END
CALL Errorout 0
/* Errorout procedure */
ErrorOut:
PARSE ARG ExitCode
IF (EXISTS( TEMP_FILE )) THEN DO
ADDRESS COMMAND "Delete >NIL:" TEMP_FILE
END
EXIT ExitCode
/* IE's error procedure */
Error:
if RC=5 then do /* Did the user just cancel us? */
IE_TO_FRONT
LAST_ERROR
'REQUEST "'||RESULT||'"'
exit
end
else do
IE_TO_FRONT
LAST_ERROR
'REQUEST "Error detected!!!'||D2C(10)||'Image Engineer error message is as follows'||D2C(10)||result||D2C(10)||'Script failed on line '||SIGL||'"' 'Doh!'